This is a dynammic template created for the Jupiter project. It is 1024px wide and 768px high. The mold has no margin at all, though the effect of "xMidYMid meet" often means that
that there is some margin after all. In orer for the mold to be dynamic, there are 2 matrices that have to be set, one for the image and keyline, the other for
the caption. Normally (aleways?) the caption is left wehre it is, bottom-aligned to the screen
The image matrix are calculated as:
- find the bbox of the mold (on this case, 100% of page size)
- find the center of that bbox, this is tx, ty values for the matrix. Find the aspect ratio (h/w) of the image,
- if it lesss than one, then the width of the bbox is sx and sy=bbox_height* aspect_ratio
- else if it more than one, then the height of the bbox is sy and sx=bbox_width/aspect_ratio
The caption matrix is calculated as:
- get the image's outline's bounding box and center point (as x and y in the info-rect)
- add half the height of the image's bbox to the center point y-value
- Get the bounding box of text-region, only the height is important.
- Add the half the height of the the text-regions bbox
- Add some spacing, e.g. 12 points so there is a gap between the text-region and the bbox of the image
- Set the resulting value as the ty value in the matrix. Note that the matrix is on the parent of the path-region.
- if this results in he caption being off the screen, simply bottom-align the caption.
<templateDescription systemLanguage="en" infoLink="www.adobe.com">This simple template is great for non-standard sized photos such as panoramic or skyscraper dimensions. It is also useful for viewing photos in full screen view.</templateDescription>